package cn.itsource.autoconfigure;

import cn.itsource.properties.CosProperties;
import cn.itsource.template.CosTemplate;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

//微信的自动配置类
//标记配置类
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties(CosProperties.class)
@Slf4j
public class UploadAutoConfiguration {

    //定义Bean
    @Bean
    CosTemplate cosTemplate(CosProperties properties){
        return new CosTemplate(properties);
    }

}
